package com.dgshanger.sanhxiaofeisc.mvp.contract;

import com.dgshanger.sanhxiaofeisc.entity.UserEntity;
import com.xx.baseuilibrary.mvp.lcec.BaseMvpLcecView;
import com.xx.baseutilslibrary.network.rx.RxHttpObserver;

import java.io.File;

/**
 * PersonContract
 * 沉迷学习不能自拔
 * Describe：
 * Created by 雷小星🍀 on 2018/4/26 17:06.
 */

public interface PersonContract {

    interface Model {
        /**
         * 获取用户信息
         */
        void getUserInfo(RxHttpObserver<UserEntity> httpObserver);

        /**
         * 上传头像
         */
        void fileStore(File file, RxHttpObserver<Object> httpObserver);

        /**
         * 存储用户信息
         */
        void putUserEntity(UserEntity entity);
    }

    interface View extends BaseMvpLcecView<UserEntity> {
        /**
         * 设置刷新状态
         *
         * @param refreshing 刷新状态
         */
        void setRefreshing(boolean refreshing);

        /**
         * 修改头像成功
         */
        void editAvatarSuccess();
    }

    interface Presenter {
        /**
         * 获取用户信息
         */
        void getUserInfo();

        /**
         * 上传头像
         */
        void fileStore(File file);
    }

}
